
using System;

namespace Subsync.Core.Sync
{

	public enum SyncMethod {
		Media,
		Network,
	}
	
	public enum MediaState {
		Repo2Media,
		MediaRepo,
		Media2Repo,
	}

	public class Sync
	{
		
		//properties?
		public string name;
		public string repo_url;
		public string working_path;
		public SyncMethod method;
		
		public Sync(string name,string repo_url,string working_path,SyncMethod method) {
			this.name = name;
			this.repo_url = repo_url;
			this.working_path = working_path;
			this.method = method;
			SyncConfigWriter config_writer = new SyncConfigWriter();
			if (!config_writer.verifySync(this)) throw new SyncNotFound();
		}
		
		public Sync(string name) {
			if (!findSync(this,name)) throw new SyncNotFound();
		}
		
		public void toggleMethod() {
			if (method == SyncMethod.Media) method = SyncMethod.Network;
			else method = SyncMethod.Media;
		}
		
		public void addRemoteSync() {
						
		}
		
		public void addLocalSync() {
			
		}
		
		public void addMediaSync() {
		
		}
		
		/// <summary>
		/// Begin Sync
		/// </summary>
		public void Execute() {
			
		}
		
	}
	
	public class SyncConfigWriter {
		
		public bool verifySync(Sync sync) {
		}
		
		public bool findSync(Sync sync, string sync_name) {
		}
		
	}
	
}
